package com.jf3q.sup.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 
 * @TableName employees
 */
@TableName(value ="employees")
@Data
public class Employees implements Serializable {
    /**
     * 员工ID,主键,自增
     */
    @TableId(type = IdType.AUTO)
    private Integer id;

    /**
     * 用户id，外键
     */
    private Integer userId;

    /**
     * 员工姓名
     */
    private String name;

    /**
     * 员工邮箱,唯一
     */
    private String email;

    /**
     * 员工电话
     */
    private String phone;

    /**
     * 员工地址
     */
    private String address;

    /**
     * 所属部门ID,外键参考部门表
     */
    private Integer departmentId;

    /**
     * 岗位ID,外键参考岗位表
     */
    private Integer positionId;

    /**
     * 入职日期
     */
    private Date hireDate;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createdAt;

    /**
     * 更新时间
     */

    private Date updatedAt;

    @TableField(exist = false)
    private Integer status;

    @TableField(exist = false)
    private String username;

    @TableField(exist = false)
    private String deptName;
    @TableField(exist = false)
    private String password;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}